
<!DOCTYPE html>
<html>
<head>
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>

<link rel="stylesheet" type="text/css" href="theme/layui/css/layui.css">
<link rel="stylesheet" type="text/css" href="theme/default/css/common.css">
<script src="theme/default/Js/Common.js"></script>
<script src="theme/default/Js/jquery-3.0.0.min.js"></script>
<script src="theme/default/js/artDialog.js?skin=blue"></script>
<link rel="stylesheet" type="text/css" href="include/webupload/webuploader.css">
<script src="include/webupload/webuploader.min.js"></script> 
<script src="include/webupload/uploads.js"></script>
<link rel='stylesheet' type="text/css" href='/theme/desktop/css/font-awesome.min.css'>
<!--上传-->
<link rel="stylesheet" type="text/css" href="include/webupload/webuploader.css">
<script src="include/webupload/webuploader.min.js"></script>
<script src="include/webupload/uploads.js"></script>
<style>
.btns{ min-width:100px; float:left; height:25px; line-height:25px;}
.webuploader-pick {
	padding:2px 15px;
}
.uploader-list {
	min-width:100px;
	float:left;
	margin-right:20px;
	line-height: 40px;
}
.webuploadinfo {
	font-weight:bold;
	margin-right:10px;
}
.webuploadDelbtn {
	color:#F00;
	margin-left:10px;
}
</style>

</head>
<body>

<script>
<!-- 必填项提示
function CheckInput()
{
	if (1=="1"){if(document.all.gLinkman.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '客户联系人不能为空'});document.all.gLinkman.focus();return false;}}
	if (1=="1"){if(document.all.sType.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '工单类型不能为空'});document.all.sType.focus();return false;}}
	if (1=="1"){if(document.all.gRenyuan.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '指派人员不能为空'});document.all.gRenyuan.focus();return false;}}
	if (1=="1"){if(document.all.gSdate.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '起始日期不能为空'});document.all.gSdate.focus();return false;}}
	if (1=="1"){if(document.all.gEdate.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '结束日期不能为空'});document.all.gEdate.focus();return false;}}
	if (0=="1"){if(document.all.gJiaotong.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '交通方式不能为空'});document.all.gJiaotong.focus();return false;}}
	if (0=="1"){if(document.all.gLianxiren.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '差旅联系人不能为空'});document.all.gLianxiren.focus();return false;}}
	/*if (1=="1"){if(document.all.gGongzuo.value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '工作描述不能为空'});document.all.gGongzuo.focus();return false;}}*/
	
	

	
	
}
-->
</script>

<!----------------------------------------新增工单信息开始----------------------------------------> 
<!----------------------------------------新增工单信息开始---------------------------------------->
<div class="cssout">
  <form class="layui-form" name="save" action="?action=gongdan&stype=saveadd&LaiLu=" method="post" onSubmit="return CheckInput();">
    <div class="cssin">
      <ul>
        <li class="w100 bg">
          <dd class="isin"><B>新增工单信息</B></dd>
        </li>
        <li class="w25 bg cl tr">
          <dd class="isin"> <font color="#FF0000">*</font> 客户名称</dd>
        </li>
        <li class="w75">
          <dd class="isin"> sdsdsdd ( 编号 : 9 )
            
            <input name="Chongxuan" type="button" id="Chongxuan" class="btn1 btnchongx" value="重选" onclick='$.dialog.open.origin.Infoadd_Chose();$.dialog.close();'>
            
          </dd>
        </li>
        
        <li class="w25 bg cl tr">
          <dd class="isin">
            
            <font color="#FF0000">*</font>
            
            客户联系人</dd>
        </li>
        <li class="w75">
          <dd class="isin">
            <select name="gLinkman" id="gLinkman" onChange="Getselectids();"><option value="">请选择</option><option value="sddsdfsdsf" tel="15669365326" selected>sddsdfsdsf</option></select>
           
            
            </dd>
        </li>
        <li class="w25 bg cl tr">
          <dd class="isin">
            
            <font color="#FF0000">*</font> 工单类型
            
          </dd>
        </li>
        <li class="w75">
          <dd class="isin">
            <select name="sType" id="Select_gongdan"><option value="">请选择</option><option value="售后工单">售后工单</option><option value="订单配送">订单配送</option></select>
            
            
           
        </li>
        <li class="w25 bg cl tr">
          <dd class="isin">
            
            <font color="#FF0000">*</font>
            
            指派人员 </dd>
        </li>
        <li class="w75">
          <dd class="isin">
            <input name="gRenyuan" type="text" class="bor int" id="gRenyuan" value="" size="40" readonly>
            
           
          </dd>
        </li>
        <li class="w25 bg cl tr">
          <dd class="isin">
            
            <font color="#FF0000">*</font>
            
            起始日期 </dd>
        </li>
        <li class="w75">
          <dd class="isin">
            <input name="gSdate" type="text" id="gSdate" class="int Wdate" size="22" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd'})" />
          </dd>
        </li>
        <li class="w25 bg cl tr">
          <dd class="isin">
            
            <font color="#FF0000">*</font>
            
            结束日期 </dd>
        </li>
        <li class="w75">
          <dd class="isin">
            <input name="gEdate" type="text" id="gEdate" class="int Wdate" size="22" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd'})" />
          </dd>
        </li>
        <li class="w25 bg cl tr">
          <dd class="isin">
            
            交通方式 </dd>
        </li>
        <li class="w75">
          <dd class="isin">
            <select name="gJiaotong" id="Select_jiaotong"><option value="">请选择</option><option value="火车">火车</option></select>
           
            
          
          </dd>
        </li>
        
        
        <li class="w25 bg cl duohang tr" style="height:265px;">
          <dd class="isin">
            
            <font color="#FF0000">*</font>
            
            工作描述</dd>
        </li>
        <li class="w75 duohang" style="height:265px;">
        
        <!-- 加载编辑器的容器 -->
        <dd class="isin" style="padding:5px;">
          <textarea class="layui-textarea layui-hide" name="gGongzuo" id="gGongzuo"></textarea>
        </dd>
        </li>
        
        
<div class="zidonggaodu fujian">
        <li class="w25 cl bg tr">
          <dd class="isin">
            附件</dd>
        </li>
        <li class="w75">
          <dd class="isin">
          
<span id="fujian1"> </span>
<script>
//定义一个上传
var upName1 = $("#fujian1").powerWebUpload(
{ 
	auto: true,//上传后是否自动上传
	fileNumLimit:10,//允许上传个数
	accept: {
	   title: '上传附件',
	   extensions: 'gif,jpg,png,bmp,doc,docx,xls,xlsx,ppt,pdf,rar,zip,txt',//允许类型 原始：'gif,jpg,jpeg,bmp,png'
	   mimeTypes: '*'//类型 原始：'image/*'
	}//限制的配置信息
});
//绑定上传完成事件 file 参数中有 原始名称 大小 后缀 类型等等参数；percentage是服务返回的参数 有信息 和图片地址
    upName1.on('uploadSuccess', function (file, percentage) {
	$("#fujianlist").val(percentage.data.src);
	
});
</script>
          </dd>
        </li>
        <div class="clear"></div>
</div>
        
        
        
        <li class="w25 bg cl tr">
          <dd class="isin"> 工作记录 </dd>
        </li>
        <li class="w75">
          <dd class="isin">
            <input type="button" class="btn1 btnfujianno" value="请先建立工单，再添加工作记录" title="请先建立工单，再添加工作记录" />
          </dd>
        </li>
        
        <!--<li class="w25 bg cl tr">
          <dd class="isin"> <font color="#FF0000">*</font> 
          
          </dd>
        </li>
        <li class="w75">
          <dd class="isin">
            
		  </dd>
        </li>-->
        
        
        <div class="clear"></div>
      </ul>
    </div>
    <div class="h50b"></div>
    <div class="fixed_bg_B">
      <input name="cid" type="hidden" value="9">
      <input name="guser" type="hidden" value="超级管理员">
      <input type="submit" name="Submit" class="btn2 btnbaoc" value="保存" >
      <input name="Back" type="button" id="Back" class="btn2 btnguanb" value="关闭" onClick="art.dialog.close();guanbi();">
      
    
      
    </div>
  </form>
</div>

<script src="theme/default/WdatePicker.js"></script> 
<script src="theme/layui/layui.js"></script> 
<script src="theme/desktop/js/common.js"></script> 
<script>
layui.use(['form', 'layedit', 'laydate'], function(){
  var form = layui.form()
  ,layer = layui.layer
  ,layedit = layui.layedit
  ,laydate = layui.laydate;
  
  //创建一个编辑器
  var editindex = layedit.build('gGongzuo', {
	  height: 210 , //设置编辑器高度
	uploadImage: {
	  url: '/include/inc/upload.asp?dopost=image' //接口url
	  ,type: '' //默认post
	}
  }); 
  //创建一个编辑器
  var editIndex2 = layedit.build('oReply', {
	height: 170 , //设置编辑器高度
	uploadImage: {
	  url: '/include/inc/upload.asp?dopost=image' //接口url
	  ,type: '' //默认post
	}
  }); 
  //var editIndex2 = layedit.build('oReply');
});
</script>

<script>
/*弹出窗口封装代码*/
$(".open-app").on("click",function(){
	var width = $(this).data("width")?$(this).data("width"):900,//获得宽度
	height = $(this).data("height")?$(this).data("height"):400//获得高度
	url = $(this).attr("href")//获得打开URL
	title = $(this).attr("title");//获得标题	
	$.dialog.open(url, {title: title, width:width,height:height, fixed: true});
	return false;	
})
</script>

<script>
function Setdisabled(evt)
{
	
	 if(evt=="0")
	 {
		document.all.gclbz.disabled = true; document.all.gclbz.readOnly = true;
		document.all.gcltime.disabled = true; document.all.gcltime.readOnly = true;
		document.all.gcltime.classname = "";document.all.gcltime.value = "";
		 
	 }
	 else
	 {
		document.all.gclbz.disabled = false; document.all.gclbz.readOnly = false;
		document.all.gcltime.disabled = false; document.all.gcltime.readOnly = false;
		document.all.gcltime.classname = "Wdate int";document.all.gcltime.value = "2017-12-20";
	 }
}
</script>
</body>
</html>
